package org.oc.qaq.entity.elasticsearch;

import lombok.Data;
import org.springframework.data.annotation.Id;
import org.springframework.data.elasticsearch.annotations.Document;
import org.springframework.data.elasticsearch.annotations.Field;
import org.springframework.data.elasticsearch.annotations.FieldType;

@Data
@Document(indexName = "article")
public class DocumentSegment {

    @Id
    private String docId;
    private String title;
    private Integer pageNum;   // 可用于分页、展示顺序

    @Field(type = FieldType.Text, analyzer = "ik_max_word")
    private String content;
}